    var ge;
    
    google.load("earth", "1");
    
    function initGE() {
      google.earth.createInstance('map3d', initCallback, failureCallback);
    }
    
    function initCallback(instance) {
      ge = instance;
      ge.getWindow().setVisibility(true);
    
      // add a navigation control
      ge.getNavigationControl().setVisibility(ge.VISIBILITY_AUTO);
    
      // add some layers
      ge.getLayerRoot().enableLayerById(ge.LAYER_BORDERS, true);
      ge.getLayerRoot().enableLayerById(ge.LAYER_ROADS, true);
    
      // in this sample we will attempt
      // to fetch a  KML file and show it
    
      function finished(object) {
        if (!object) {
          // wrap alerts in API callbacks and event handlers
          // in a setTimeout to prevent deadlock in some browsers
          setTimeout(function() {
            alert('Bad or null KML.');
          }, 0);
          return;
        }
        ge.getFeatures().appendChild(object);
        var la = ge.createLookAt('');
        la.set(48.823044, 2.326698, 25, ge.ALTITUDE_RELATIVE_TO_GROUND,
               180, 60, 500);
        ge.getView().setAbstractView(la);
      }
    
      // fetch the KML
      var url = 'http://www.gevu.org/carto/LogisTransport1.kmz';
      google.earth.fetchKml(ge, url, finished);
    
      document.getElementById('installed-plugin-version').innerHTML =
        ge.getPluginVersion().toString();
    }
    
    function failureCallback(errorCode) {
    }
    var myPano;
    function initST() {
        myPano = new GStreetviewPanorama(document.getElementById("pano"));
        GEvent.addListener(myPano, "error", handleNoFlash);
      }
      
    function montreST(lat, lng, head, pitch){
        //vérifie si streetview est chargé
    	if(!myPano)initST();
    	fenwayPark = new GLatLng(lat, lng);
        myPOV = {yaw:head,pitch:pitch};
        myPano.setLocationAndPOV(fenwayPark, myPOV);    	
    }
    
      function handleNoFlash(errorCode) {
        if (errorCode == 603) {
          alert("Error: Flash doesn't appear to be supported by your browser");
          return;
        }
      }  
